package day5;

public class factor {

	public static void main(String[] args) {
		int sum = 0;
		for(int i = 1; i <= 1000;i++) {
			for(int j = 1;j <= i/2;j++) {
				if(i % j == 0) {
					sum += j;
				}
			}
			if(i == sum) {
				System.out.println(i);
			}
			sum = 0;
		}

	}

}
